package com.hksj.em.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.hksj.em.entity.OperationRoom;
import com.hksj.em.query.OperationRoomQuery;
import com.hksj.em.vo.LatestOperationRoomVO;
import com.hksj.em.vo.OperationRoomDataVO;
import com.hksj.em.vo.OperationRoomFromHisVO;
import com.hksj.em.vo.OperationRoomVO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @author zengke
 * @version 1.0
 * @see OperationRoomMapper
 * @since 2025/03/25 10:15
 */

@Mapper
public interface OperationRoomMapper extends BaseMapper<OperationRoom> {

    /**
     * 分页查询手术室列表
     * @param page 分页对象
     * @param query 手术室查询对象
     * @return 分页结果
     */
    List<OperationRoomVO> queryOperationRoomListByPaging(IPage<OperationRoomVO> page, @Param("query") OperationRoomQuery query);

    /**
     * 查询his源的手术室列表
     * @return 手术室列表
     */
    List<OperationRoomFromHisVO> queryOperationRoomFromHisList();

    /**
     * 分页查询最新手术室信息
     * @param query 手术室查询条件
     * @return 分页结果
     */
    List<LatestOperationRoomVO> queryLatestOperationRoomInfoListByPaging(IPage<LatestOperationRoomVO> page,@Param("query") OperationRoomQuery query);

    /**
     * 根据手术室code查询手术室数据
     * @param roomCode 手术室code
     * @return 手术室数据列表
     */
    List<OperationRoomDataVO> queryOperationRoomDataList(@Param("roomCode") String roomCode);
}
